import request from '@/utils/request'

export function page({ name, author, press, isbn, publishTime, price, borrower, borrowTime, deadline, returnTime, status,id, page, pageSize }) {
    return request({
        url: 'record/page',
        method: 'get',
        params: {
            name,
            author,
            press,
            isbn,
            publishTime,
            price,
            borrower,
            borrowTime,
            deadline,
            returnTime,
            status,
            id,
            page,
            pageSize
        }
    })
}

export function getById(isbn) {
    return request({
        url: 'record/' + isbn,
        method: 'get',
    })
}
export function update(record) {
    return request({
        url: 'record/update',
        method: 'put',
        data: record
    })
}